import React, { Component } from 'react';

class Son extends Component {
    render() {
        return (
            <div>
                {/* <p>我是子组件--{this.props.username}</p> */}
            </div>
        );
    };
    componentDidMount() {
        // console.log(this.props.fun());
    };

    getstatefromfather(data) {
        // 该data 就是父组件传递的数据
        console.log('data', data);
    }
}

export default Son;
